home *** CD-ROM | disk | FTP | other *** search
/ Compute! Gazette 1984 June / 1984-06.d64 / spell critter.vi (.txt) < prev    next >
Commodore BASIC  |  2022-09-20  |  2KB  |  109 lines

  1. 2 print"[147]spelling critter"
  2. 15 print"one moment please"
  3. 20 poke36869,255
  4. 21 poke52,28:poke56,28:clr
  5. 22 fori=7168to7679:pokei,peek(i+25600):next
  6. 23 forc=7168to7175:reada:pokec,a:next
  7. 24 forc=7664to7671:reada:pokec,a:next
  8. 25 forc=7656to7663:reada:pokec,a:next
  9. 30 data96,128,77,63,31,13,0,0
  10. 31 data3,52,184,240,240,184,52,3
  11. 32 data0,54,58,242,242,58,54,0
  12. 50 dimw$(50)
  13. 60 print"[147]"
  14. 61 poke36878,15
  15. 70 print"hi,what is your"
  16. 75 input"name";n$
  17. 80 gosub5000
  18. 90 w=0:r=0:z=0
  19. 100 forb=1ton
  20. 120 print"[147]"w$(b)
  21. 140 fort=1to1000:next
  22. 160 print"[147]":a$=""
  23. 165 print"  to review the word  "
  24. 166 print"  type ? and return   "
  25. 180 print"how do you spell":print
  26. 190 input"that word";a$
  27. 195 ifa$=""orlen(a$)=0then160
  28. 200 ifa$="that word"thengosub6000:goto160
  29. 210 ifa$="?"ora$="/"then120
  30. 220 ifa$=w$(b)thengosub7000:goto400
  31. 230 gosub8000
  32. 240 print"[147]i'm sorry,"n$:print
  33. 260 print"that is wrong":print
  34. 270 poke36874,223
  35. 274 fort=1to500:next
  36. 275 poke36874,0
  37. 280 print"the correct way is:"
  38. 300 print"[144]"w$(b)""
  39. 320 w=w+1
  40. 340 goto450
  41. 400 print"that is right"
  42. 420 print"very good ";n$
  43. 424 m=220
  44. 425 forp=1to8
  45. 427 m=m+3
  46. 429 poke36876,m
  47. 430 fort=1to25
  48. 431 poke36876,0
  49. 432 nextp
  50. 433 restore
  51. 440 r=r+1
  52. 450 poke198,0:print"hit any key"
  53. 460 getz$:ifz$=""then460
  54. 480 nextb
  55. 500 print"[147]you had "r" right and ":print
  56. 510 printw" wrong."
  57. 550 print"would you like to":print
  58. 560 print"try again (y/n)?"
  59. 580 getz$:ifz$=""or(z$<>"y"andz$<>"n")then580
  60. 590 ifz$="y"then80
  61. 600 print"[147]it has been very nice":print:print"spelling with you":print
  62. 620 printn$"."
  63. 640 print"please come back again":print
  64. 650 print"to play real soon."
  65. 660 print"bye!"
  66. 700 end
  67. 5000 rem input
  68. 5050 print"[147]how many words do we"
  69. 5060 input"have today";z$:n=val(z$):ifn>50orn=0then5050
  70. 5100 forx=1ton
  71. 5150 print"[147][160]check your spelling!![146]"
  72. 5200 print"word #";x;:input"[157]";w$(x)
  73. 5210 iflen(w$(x))=0orlen(w$(x))>10then5150
  74. 5220 ifasc(w$(x))<65orasc(w$(x))>90then5150
  75. 5250 nextx
  76. 5300 return
  77. 6000 rem wiseguy
  78. 6010 print"very funny,wiseguy":print
  79. 6015 fort=1to1000:next
  80. 6020 fort=1to500:next
  81. 6030 return
  82. 7000 q=0
  83. 7001 l=7900:co=38620
  84. 7010 pokel+q,0:pokeco+q,4
  85. 7020 pokel+q+1,61:pokeco+q+1,4
  86. 7030 fort=1to50:next
  87. 7040 pokel+q+1,62:pokeco+q+1,4
  88. 7042 poke36877,160:fort=1to10:next
  89. 7045 poke36877,0
  90. 7050 fort=1to50:next
  91. 7060 ifq=9thenreturn
  92. 7070 pokel+q,32
  93. 7075 q=q+1
  94. 7080 goto7001
  95. 8000 q=0
  96. 8001 l=7900:co=38620
  97. 8010 pokel+q,0:pokeco+q,4
  98. 8020 pokel+q+1,61:pokel+q+1,4
  99. 8030 fort=1to50:next
  100. 8040 pokel+q+1,62:pokeco+q+1,4
  101. 8042 poke36877,160:fort=1to10:next
  102. 8045 poke36877,0
  103. 8050 fort=1to50:next
  104. 8060 pokel+q,32
  105. 8070 ifq=20thenpokel+q+1,32:return
  106. 8075 q=q+1
  107. 8080 goto8001
  108. 9000 end
  109.